package com.ddwl.gate.controller;


import com.ddwl.common.controller.BaseController;
import com.ddwl.schema.vo.base.RestVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.time.Instant;

/**
 * @author time
 * @date 2017/1/3
 */
@Api(tags = "时间服务")
@RequestMapping("/time")
@RestController
public class TimeController extends BaseController {

    @GetMapping("/getTime")
    @ApiOperation("获取当前系统时间")
    public RestVo<Instant> getTime() {
        return RestVo.ok(Instant.now());
    }


}
